/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Topka;

import java.io.IOException;
import java.net.ServerSocket;
import java.net.Socket;

/**
 *
 * @author Asko
 */
public class Server {

    public static void main(String args[]) {
        try {
            ServerSocket ss = new ServerSocket(3456);
            System.out.println("Waiting...");
            Socket client = ss.accept();
            System.out.println("Connected");
            client.getOutputStream().write("Sniper here".getBytes("UTF-8"));
            client.close();
            ss.close();
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}
